import subprocess
import time
p = subprocess.Popen(['python','cat1.py','a.txt'],stdout=subprocess.PIPE)
stdout,stderr = p.communicate()

stdout = stdout.decode()
print(stdout)
time.sleep(5)